package com.java.escape.springproblem;

import com.java.escape.springproblem.applicationcontext.ApplicationContextStore;
//import com.java.escape.springproblem.applicationcontext.UseInitializer;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * @ClassName SpringProblemApplication
 * @Description 获取应用上下文的几种方式
 * @Author wyp
 * @Date 2023/9/11 10:44
 * @Version 1.0
 */

@SpringBootApplication
public class SpringProblemApplication {
    public static void main(String[] args) {
        SpringApplication.run(SpringProblemApplication.class, args);
//        SpringApplication springApplication = new SpringApplication(
//                SpringProblemApplication.class
//        );
//        springApplication.addInitializers(new UseInitializer());
//        springApplication.run(args);
//        ApplicationContextStore.setApplicationContext(SpringApplication.run(SpringProblemApplication.class, args));
    }
}
